{:W("Main",array('module'=>MODULE_NAME,'action'=>ACTION_NAME,'do'=>$_GET['do']))}

<div class="layout-main">    
    <div id="breadclumb" class="box">
        <h3><strong>{:lang('breadclumb_colon')}</strong>{:lang(MODULE_NAME)}<span></span>{:lang('order_list')}</h3>
    </div>
    <div id="CooperationMain" class="box clear-fix">   
        <div class="layout-block-header">
            <form action="__SELF__" method="get" id="searchform">
            	<input type="hidden" name="s" value="{$Think.const.MODULE_NAME}" />
				<input type="hidden" name="a" value="{$Think.const.ACTION_NAME}" />
                <label>{:lang('order_search_colon')}</label>
				<select name="fields">
					<php>$fields=array('order_no'=>lang('order_number'),'item_name'=>lang('item_name'),'name'=>lang('customer_realname'),'mobile'=>lang('customer_mobile'));</php>
					<volist name="fields" id="vo">
					<option value="{$key}" <eq name="_GET.fields" value="$key">selected='selected'</eq>>{$vo}</option>
					</volist>
				</select>
                <input type="text" name="keyword" value="{$_GET['keyword']|trim}" class="ui-text" autocomplete="off" size="40">
                <button type="submit" class="btn btn-ok">{:lang('search')}</button>
				
				<div class="search-list filter clear-fix">
                    <label>{:lang('booking_time_colon')}</label>
                    <input type="text" name="time_start" value="{$_GET['time_start']|trim}" size="11" class="ui-text Wdate" onclick="WdatePicker();">{:lang('to')}<input type="text" name="time_end" value="{$_GET['time_end']|trim}" size="11" class="ui-text Wdate" onclick="WdatePicker();">
                </div>
				
            </form>
        </div>
        
		<form action="{:U('Recycle/todo')}" method="post" id="deleteform">
        <div class="ui-table">
            <div class="ui-table-body ui-table-body-hover">
                <table cellpadding="0" cellspacing="0" width="100%" >
                    <thead>
                        <tr class="ui-table-head">
                            <th class="ui-table-hcell" width="15"><input type="checkbox" id="check_box" onclick="$.Select.All(this,'id[]');" ></th>
                            <th class="ui-table-hcell">{:lang('item_name')}</th>
                            <th class="ui-table-hcell" width="50">{:lang('amount_price')}</th>
                            <th class="ui-table-hcell" width="60">{:lang('customer_realname')}</th>
                            <th class="ui-table-hcell" width="80">{:lang('customer_mobile')}</th>
							<th class="ui-table-hcell" width="50">{:lang('payment')}</th>
							<th class="ui-table-hcell" width="50">{:lang('status')}</th>
                            <th class="ui-table-hcell" width="100">{:lang('time')}</th>
                        </tr>
                    </thead>
                    <tbody>
						<php>$payment = C('PAYMENT');</php>
                        <volist name="list" id="vo">
                        <tr id="row-{$vo.id}">
                            <td><input type="checkbox" name="id[]" value="{$vo.id}" onclick="$.Select.This(this);"></td>
                            <td>{$vo.item_name}<notempty name="vo.item_params">（{$vo.item_params}）</notempty></td>
                            <td>{$vo.quantity}/<b class="alert">{$vo.total_price}</b></td>
                            <td>{$vo.name}</td>
                            <td>{$vo.mobile}</td>
                            <td>{$payment[$vo['payment']]['name']}</td>
                            <td>{:status($vo['status'],'',C('order_status'))}</td>
                            <td>{$vo.add_time|date="Y-m-d H:i",###}</td>
                        </tr>
                        </volist>
                    </tbody>
                </table>
            </div>
        </div>
          
        <div class="ui-pager-bar clearfix" style="padding-left:10px;">
			<div class="float-left">
				<input type="hidden" name="model" value="Order">
				<input type="checkbox" id="check_box" onclick="$.Select.All(this,'id[]');" >选择/反选 
				<input type="submit" name="recover" value="恢复" class="btn btn-ok">
				<input type="button" name="delete" value="批量删除" class="btn" onclick="delConfirm()">
			</div>
			<div class="ui-pager" style="float:right">{$page}</div>
		</div>
		
		</form>
</div><!--.box-->
<script type="text/javascript" src="__PUBLIC__/Assets/js/My97DatePicker/WdatePicker.js"></script>
<script type="text/javascript">
function Open(id,title){
	var url = "?m=Order&a=todo&id="+id;
	$.open(url,{title:'订单操作 - '+title,width:550,height:220})
}
function delConfirm(){
	$.confirm('是否要删除？',function(){ 
		$('#deleteform').submit();
	},true)
}
</script>
{:W("Foot")}   